﻿using System;
using System.Web.UI.WebControls;

namespace EXAM.Admin
{
    public partial class Admin : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                if (Session["UserAdmin"] == null)
                    Response.Redirect("~/Admin/Login.aspx");
            }

            if (Request.Url == Request.UrlReferrer)
            {
                //string script =" window.onbeforeunload = function(){if((window.event.clientX&lt;0) || (window.event.clientY&lt;0)){ return 'please close the window with caution' ;} " 
                // ClientScript.RegisterStartupScript(Page.GetType, "promptclose", script)

            }
        }
    }


}
